package com.dap.configuration.utils;

import com.baidu.disconf.core.common.constants.Constants;

/**
 * Zoo path 管理
 *
 * @author liaoqiqi
 * @version 2014-6-16
 */
public class ZooPathExtensionMgr {

	/**
	 * @return String
	 *
	 * @Description: 获取ZOOKEEPER的应用基础路径
	 * @author liaoqiqi
	 * @date 2013-6-17
	 */
	public static String getZooBaseUrl(String urlPrefix, String app,
			String env, String version, String bankKey) {

		StringBuffer sb = new StringBuffer();
		sb.append(urlPrefix);

		sb.append(Constants.SEP_STRING);
		sb.append(bankKey);

		sb.append(Constants.SEP_STRING);
		sb.append(app);

		sb.append("_");
		sb.append(version);

		sb.append("_");
		sb.append(env);

		return sb.toString();
	}

}
